package com.xidian.zhiancloud.controller.chemicalsManagement.wastePart;


import com.xidian.zhiancloud.dto.ResultDTO;
import com.xidian.zhiancloud.enums.GeneralResponseEnums;
import com.xidian.zhiancloud.service.chemicalsManagement.chemicalManager.wastePart.WasteTypeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * 危化品管理 废弃物库存管理 废弃物类型
 * @Author: Egoist
 * @Date: 2020/11/10 17:31
 */
@RestController
@RequestMapping("/WasteType")
public class WasteTypeController {

    @Autowired
    private WasteTypeService wasteTypeService;

    /**
     * 获取废弃物类型列表
     * @return 废弃物类型列表
     */
    @GetMapping("/getList")
    public ResultDTO<Map<Long, String>> getWasteTypeList(){
        return ResultDTO.successOf(wasteTypeService.getList(), GeneralResponseEnums.SUCCESS);
    }


}
